package demo1109.demo01;

import java.security.PublicKey;

/**
 * @author JYH
 * @version 1.0
 * @date 2022/11/9 9:38
 */
public class JingJiRen implements Show{

    private MingXing target;

    public JingJiRen(MingXing target) {
        this.target = target;
    }

    public void show(){
        System.out.println("问候");
        target.sing();
        target.dance();
        System.out.println("答谢");

    }

    public void sing() {
        System.out.println("唱歌");
    }

    public void dance() {
        System.out.println("跳舞");
    }
}
